FROM  swr.cn-east-4.myhuaweicloud.com/swr-tool/node:20.18.0 as build
ADD rd-gdm-AIRuleInput-web /app
WORKDIR /app/@folder
RUN npm i &&  npm run build 

FROM swr.cn-east-4.myhuaweicloud.com/swr-base/nginx-120:1-55
MAINTAINER "nancal"
ENV TZ "Asia/Shanghai"
RUN echo "${TZ}" > /etc/timezone \
    && ln -sf /usr/share/zoneinfo/${TZ} /etc/localtime
WORKDIR /app
COPY --from=build /app/@folder/dist /app
ADD nginx.conf /etc/nginx/conf.d/default.conf
ENV LC_ALL=en_US.UTF-8